package com.xrz.sxm.aj.view;

import android.content.Context;
import android.util.AttributeSet;
import android.widget.CheckBox;
import android.widget.LinearLayout;

public class TestView extends LinearLayout{

	public TestView(Context context, AttributeSet attrs, int defStyle) {
		super(context, attrs, defStyle);
		init();
	}

	public TestView(Context context, AttributeSet attrs) {
		super(context, attrs);
		init();
	}

	public TestView(Context context) {
		super(context);
		init();
	}

	private void init(){
		setOrientation(HORIZONTAL);
		for(int i=0;i<5;i++){
			createCheckBox("test");
		}
	}
	
	private CheckBox createCheckBox(String text){
		CheckBox checkBox = new CheckBox(getContext());
		checkBox.setText(text);
		return checkBox;
	}
}
